<h3>Select Contact</h3>

<?php

$this->widget('PsGridView', array(
	'id' => 'search-contacts-grid',
	'dataProvider' => $contactDataProvider,
	'filter' => $searchContact,
	'template' => '{pager}{pagesize}{items}',
	'pagerCssClass' => 'pager float-right',
	'pagesizeCssClass' => 'pager-pagesize',
	'htmlOptions' => array(
		'class' => 'grid-view no-shadow'
	),
	'rowCssClassExpression' => '($row % 2 == 0 ? "even" : "odd")',
	'columns' => array(
		'id' => array(
			'name' => 'id',
			'value' => '$data->id',
			'filter' => false,
			'htmlOptions' => array('style' => 'display:none', 'class' => 'id'),
			'headerHtmlOptions' => array('style' => 'display:none')
		),
		'party_id' => array(
			'name' => 'party_id',
			'value' => '$data->party_id',
			'filter' => false,
			'htmlOptions' => array('style' => 'display:none', 'class' => 'party_id'),
			'headerHtmlOptions' => array('style' => 'display:none')
		),
		'address' => array(
			'name' => 'address_formatted',
			'value' => '$data->address_formatted',
			'filter' => false,
			'htmlOptions' => array('style' => 'display:none', 'class' => 'address'),
			'headerHtmlOptions' => array('style' => 'display:none')
		),
		'name' => array(
			'name' => 'name',
			'value' => '$data->name',
			'htmlOptions' => array('class' => 'name'),
		),
		'company',
		'actions' => array(
			'header' => 'Actions',
			'class' => 'CButtonColumn', // protected/components/PsActionColumn.php
			'template' => '{selectParty}&nbsp;&nbsp;',
			'buttons' => array(
				'selectParty' => array(
					'label' => 'Select',
					'imageUrl' => '/images/icons/fugue/money--plus.png',
					'click' => "function(){}",
					'options' => array('type' => 'Contact')
				)
			),
//			'htmlOptions' => array(
//				'style' => 'width: 150px',
//			)
		)
	)
));
?>
			